<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>项目简介 - 英法神经翻译系统</title>
    <link href="https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600&display=swap" rel="stylesheet">
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
    <style>
        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }

        body {
            font-family: 'Poppins', 'Arial', sans-serif;
            background: linear-gradient(135deg, #667eea 0%, #efd64a 100%);
            min-height: 100vh;
            padding: 20px;
            color: #333;
            line-height: 1.6;
        }

        .container {
            max-width: 1000px;
            margin: 0 auto;
            background: white;
            border-radius: 15px;
            box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
            overflow: hidden;
        }

        .header {
            background: linear-gradient(135deg, #667eea 0%, #efd64a 100%);
            color: white;
            padding: 30px;
            text-align: center;
            position: relative;
        }

        .header h1 {
            font-size: 2.5em;
            margin-bottom: 10px;
            font-weight: 600;
        }

        .header p {
            font-size: 1.2em;
            opacity: 0.9;
            margin-bottom: 20px;
        }

        .back-button {
            position: absolute;
            top: 20px;
            left: 20px;
            padding: 10px 20px;
            background: rgba(255, 255, 255, 0.2);
            color: white;
            border: 2px solid rgba(255, 255, 255, 0.3);
            border-radius: 8px;
            cursor: pointer;
            font-size: 14px;
            font-weight: bold;
            transition: all 0.3s;
            backdrop-filter: blur(10px);
            text-decoration: none;
            display: inline-flex;
            align-items: center;
            gap: 8px;
        }

        .back-button:hover {
            background: rgba(255, 255, 255, 0.3);
            border-color: rgba(255, 255, 255, 0.5);
            transform: translateY(-2px);
        }

        .content {
            padding: 40px;
        }

        .section {
            margin-bottom: 40px;
        }

        .section-title {
            display: flex;
            align-items: center;
            gap: 15px;
            margin-bottom: 20px;
            padding-bottom: 10px;
            border-bottom: 2px solid #e9ecef;
        }

        .section-title i {
            font-size: 1.5rem;
            color: #4facfe;
        }

        .section-title h2 {
            font-size: 1.8em;
            color: #4facfe;
            font-weight: 500;
        }

        .section-content {
            padding: 0 20px;
        }

        p {
            margin-bottom: 15px;
            font-size: 1.1em;
        }

        .feature-list {
            list-style-type: none;
            margin: 20px 0;
        }

        .feature-list li {
            padding: 10px 0;
            border-bottom: 1px dashed #e9ecef;
            display: flex;
            align-items: flex-start;
            gap: 10px;
        }

        .feature-list li:last-child {
            border-bottom: none;
        }

        .feature-list i {
            color: #4facfe;
            margin-top: 5px;
        }

        .tech-stack {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
            gap: 20px;
            margin: 20px 0;
        }

        .tech-item {
            background: #f8f9fa;
            padding: 20px;
            border-radius: 10px;
            text-align: center;
            box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
            transition: transform 0.3s;
        }

        .tech-item:hover {
            transform: translateY(-5px);
        }

        .tech-item i {
            font-size: 2.5rem;
            color: #4facfe;
            margin-bottom: 15px;
        }

        .tech-item h3 {
            margin-bottom: 10px;
            color: #333;
        }

        .architecture {
            text-align: center;
            margin: 30px 0;
        }

        .architecture img {
            max-width: 100%;
            border-radius: 10px;
            box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
        }

        .caption {
            font-style: italic;
            color: #6c757d;
            margin-top: 10px;
        }

        .button-group {
            display: flex;
            gap: 15px;
            margin-top: 30px;
            flex-wrap: wrap;
        }

        .action-button {
            padding: 12px 25px;
            background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
            color: white;
            border: none;
            border-radius: 8px;
            cursor: pointer;
            font-size: 16px;
            font-weight: bold;
            transition: all 0.3s;
            display: inline-flex;
            align-items: center;
            gap: 8px;
            text-decoration: none;
        }

        .action-button:hover {
            transform: translateY(-2px);
            box-shadow: 0 5px 15px rgba(79, 172, 254, 0.4);
        }

        .secondary {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
        }

        footer {
            text-align: center;
            padding: 20px;
            color: white;
            background: linear-gradient(135deg, #667eea 0%, #efd64a 100%);
        }

        @media (max-width: 768px) {
            .content {
                padding: 20px;
            }

            .section-title h2 {
                font-size: 1.5em;
            }

            .tech-stack {
                grid-template-columns: 1fr;
            }

            .button-group {
                flex-direction: column;
            }

            .action-button {
                width: 100%;
                justify-content: center;
            }
        }
    </style>
</head>
<body>
    <div class="container">
        <div class="header">
            <a href="/" class="back-button">
                <i class="fas fa-arrow-left"></i> 返回翻译
            </a>
            <h1>英法神经翻译系统</h1>
            <p>基于Seq2Seq与注意力机制的GRU翻译模型</p>
        </div>

        <div class="content">
            <div class="section">
                <div class="section-title">
                    <i class="fas fa-info-circle"></i>
                    <h2>项目概述</h2>
                </div>
                <div class="section-content">
                    <p>本系统是一个基于深度学习的神经机器翻译模型，专门设计用于英文到法文的自动翻译。系统采用了先进的Seq2Seq（序列到序列）架构，并结合注意力机制（Attention Mechanism），显著提升了长文本的翻译质量。</p>
                    <p>与传统基于规则的机器翻译不同，本系统通过分析大量平行语料库（英文-法文对照文本）自动学习两种语言之间的映射关系，能够处理各种复杂句式和文化特定表达。</p>
                </div>
            </div>

            <div class="section">
                <div class="section-title">
                    <i class="fas fa-cogs"></i>
                    <h2>技术架构</h2>
                </div>
                <div class="section-content">
                    <p>系统核心是一个编码器-解码器（Encoder-Decoder）架构：</p>

                    <div class="architecture">
                        <img src="https://miro.medium.com/v2/resize:fit:1400/1*1JcHGUU7rFgtXC_mydUA_Q.jpeg" alt="Seq2Seq with Attention架构图">
                        <p class="caption">Seq2Seq with Attention 架构示意图</p>
                    </div>

                    <ul class="feature-list">
                        <li>
                            <i class="fas fa-chevron-right"></i>
                            <div><strong>编码器（Encoder）</strong>：使用GRU（门控循环单元）神经网络将输入英文句子编码为固定维度的上下文向量</div>
                        </li>
                        <li>
                            <i class="fas fa-chevron-right"></i>
                            <div><strong>解码器（Decoder）</strong>：使用另一个GRU网络结合注意力机制，将上下文向量解码为法文句子</div>
                        </li>
                        <li>
                            <i class="fas fa-chevron-right"></i>
                            <div><strong>注意力机制（Attention）</strong>：允许模型在生成每个法文单词时"关注"输入英文句子的不同部分，显著改善长句翻译质量</div>
                        </li>
                    </ul>
                </div>
            </div>

            <div class="section">
                <div class="section-title">
                    <i class="fas fa-star"></i>
                    <h2>主要特性</h2>
                </div>
                <div class="section-content">
                    <ul class="feature-list">
                        <li>
                            <i class="fas fa-check-circle"></i>
                            <div>高质量翻译：基于深度学习，翻译质量接近人工翻译水平</div>
                        </li>
                        <li>
                            <i class="fas fa-check-circle"></i>
                            <div>上下文理解：能够处理复杂句式和长文本，保持上下文一致性</div>
                        </li>
                        <li>
                            <i class="fas fa-check-circle"></i>
                            <div>实时翻译：优化后的模型可实现快速实时翻译</div>
                        </li>
                        <li>
                            <i class="fas fa-check-circle"></i>
                            <div>用户友好：简洁直观的Web界面，支持示例句子一键输入</div>
                        </li>
                        <li>
                            <i class="fas fa-check-circle"></i>
                            <div>可扩展性：模块化设计，易于扩展支持更多语言对</div>
                        </li>
                    </ul>
                </div>
            </div>

            <div class="section">
                <div class="section-title">
                    <i class="fas fa-code"></i>
                    <h2>技术栈</h2>
                </div>
                <div class="section-content">
                    <div class="tech-stack">
                        <div class="tech-item">
                            <i class="fab fa-python"></i>
                            <h3>Python</h3>
                            <p>主要编程语言</p>
                        </div>
                        <div class="tech-item">
                            <i class="fas fa-brain"></i>
                            <h3>PyTorch</h3>
                            <p>深度学习框架</p>
                        </div>
                        <div class="tech-item">
                            <i class="fas fa-network-wired"></i>
                            <h3>GRU</h3>
                            <p>门控循环单元神经网络</p>
                        </div>
                        <div class="tech-item">
                            <i class="fas fa-fire"></i>
                            <h3>Flask</h3>
                            <p>Web应用框架</p>
                        </div>
                        <div class="tech-item">
                            <i class="fab fa-html5"></i>
                            <h3>HTML/CSS/JS</h3>
                            <p>前端技术</p>
                        </div>
                    </div>
                </div>
            </div>

            <div class="section">
                <div class="section-title">
                    <i class="fas fa-database"></i>
                    <h2>训练数据</h2>
                </div>
                <div class="section-content">
                    <p>模型使用大规模英文-法文平行语料库进行训练，包含超过100万对句子。数据经过精心清洗和预处理，确保训练质量。</p>
                    <p>训练过程在GPU加速环境下进行，通过多轮迭代优化模型参数，最终达到当前的高精度翻译水平。</p>
                </div>
            </div>

            <div class="section">
                <div class="section-title">
                    <i class="fas fa-lightbulb"></i>
                    <h2>使用指南</h2>
                </div>
                <div class="section-content">
                    <ul class="feature-list">
                        <li>
                            <i class="fas fa-chevron-right"></i>
                            <div>在输入框中输入英文文本（支持长句和段落）</div>
                        </li>
                        <li>
                            <i class="fas fa-chevron-right"></i>
                            <div>点击"翻译"按钮获取法文翻译结果</div>
                        </li>
                        <li>
                            <i class="fas fa-chevron-right"></i>
                            <div>可以使用提供的示例句子快速体验系统功能</div>
                        </li>
                        <li>
                            <i class="fas fa-chevron-right"></i>
                            <div>点击复制按钮将翻译结果保存到剪贴板</div>
                        </li>
                    </ul>
                </div>
            </div>

            <div class="button-group">
                <a href="/" class="action-button">
                    <i class="fas fa-play"></i> 开始翻译
                </a>
                <a href="https://blog.csdn.net/your_username/your_article" class="action-button secondary" target="_blank">
                    <i class="fab fa-codepen"></i> 查看CSDN文章
                </a>
            </div>
        </div>

        <footer>
            <p>Powered by Seq2Seq with Attention • Neural Machine Translation</p>
        </footer>
    </div>

    <script>
        // 返回按钮功能
        document.querySelector('.back-button').addEventListener('click', function() {
            window.close();
        });
    </script>
<script>
        // 返回按钮功能
        document.querySelector('.button-group').addEventListener('click', function() {
            window.close();
        });
    </script>
</body>
</html>